public class BillCondition {
    private int currentPage;

    private int pageSize;

    private int from;

    public int getFrom() {
        return from;
    }

    public void setFrom(int from) {
        this.from = from;
    }

    public int getPageSize() {
        return pageSize;
    }

    public void setPageSize(int pageSize) {
        this.pageSize = pageSize;
        this.from = (currentPage - 1) * pageSize == 0 ? 0 : (currentPage - 1) * pageSize;
    }

    public int getCurrPage() {
        return currentPage;
    }

    public void setCurrPage(int currPage) {
        this.currentPage = currPage;
    }
}
